package guda.house.biz.form.village;

import guda.house.dal.dataobject.OwnerDO;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.util.List;


public class OwnerForm {

    @NotNull(message = "不能为空")
    private Long suiteId;
    @NotNull(message = "不能为空")
    private Long unitId;
    @NotNull(message = "不能为空")
    private Long buildingId;
    @NotNull(message = "不能为空")
    private Long villageId;


    @NotNull(message = "不能为空")
    @Size(min=1,max=5,message = "长度在1到5个字符之间")
    private String ownerName;
    @Size(min=0,max=18,message = "长度在0到18个字符之间")
    private String certNo;
    @Size(min=0,max=16,message = "长度在0到16个字符之间")
    private String phone;
    @Size(min=0,max=16,message = "长度在0到16个字符之间")
    private String weixin;
    @Size(min=0,max=18,message = "长度在0到18个字符之间")
    private String qq;
    @Size(min=0,max=64,message = "长度在0到64个字符之间")
    private String email;
    @NotNull(message = "不能为空")
    private Integer isEmployee;
    private Integer ownerStatus = 1;


    @Size(min=0,max=5,message = "长度在0到5个字符之间")
    private String rentName1;
    @Size(min=0,max=15,message = "长度在0到15个字符之间")
    private String rentPhone1;
    @Size(min=0,max=5,message = "长度在0到5个字符之间")
    private String rentName2;
    @Size(min=0,max=15,message = "长度在0到15个字符之间")
    private String rentPhone2;
    @Size(min=0,max=5,message = "长度在0到5个字符之间")
    private String contactName1;
    @Size(min=0,max=15,message = "长度在0到15个字符之间")
    private String contactPhone1;
    @Size(min=0,max=5,message = "长度在0到5个字符之间")
    private String contactRelation1;
    @Size(min=0,max=5,message = "长度在0到5个字符之间")
    private String contactName2;
    @Size(min=0,max=15,message = "长度在0到15个字符之间")
    private String contactPhone2;
    @Size(min=0,max=5,message = "长度在0到5个字符之间")
    private String contactRelation2;




    public OwnerDO toDO() {
        OwnerDO ownerDO = new OwnerDO();
        ownerDO.setCertNo(certNo);
        ownerDO.setEmail(email);
        ownerDO.setIsEmployee(isEmployee);
        ownerDO.setOwnerName(ownerName);
        ownerDO.setOwnerStatus(ownerStatus);
        ownerDO.setPhone(phone);
        ownerDO.setWeixin(weixin);
        ownerDO.setQq(qq);
        ownerDO.setSuiteId(suiteId);
        return ownerDO;
    }


    public String getRentName1() {
        return rentName1;
    }

    public void setRentName1(String rentName1) {
        this.rentName1 = rentName1;
    }

    public String getRentPhone1() {
        return rentPhone1;
    }

    public void setRentPhone1(String rentPhone1) {
        this.rentPhone1 = rentPhone1;
    }

    public String getRentName2() {
        return rentName2;
    }

    public void setRentName2(String rentName2) {
        this.rentName2 = rentName2;
    }

    public String getRentPhone2() {
        return rentPhone2;
    }

    public void setRentPhone2(String rentPhone2) {
        this.rentPhone2 = rentPhone2;
    }

    public String getContactName1() {
        return contactName1;
    }

    public void setContactName1(String contactName1) {
        this.contactName1 = contactName1;
    }

    public String getContactPhone1() {
        return contactPhone1;
    }

    public void setContactPhone1(String contactPhone1) {
        this.contactPhone1 = contactPhone1;
    }

    public String getContactRelation1() {
        return contactRelation1;
    }

    public void setContactRelation1(String contactRelation1) {
        this.contactRelation1 = contactRelation1;
    }

    public String getContactName2() {
        return contactName2;
    }

    public void setContactName2(String contactName2) {
        this.contactName2 = contactName2;
    }

    public String getContactPhone2() {
        return contactPhone2;
    }

    public void setContactPhone2(String contactPhone2) {
        this.contactPhone2 = contactPhone2;
    }

    public String getContactRelation2() {
        return contactRelation2;
    }

    public void setContactRelation2(String contactRelation2) {
        this.contactRelation2 = contactRelation2;
    }

    public Long getSuiteId() {
        return suiteId;
    }

    public void setSuiteId(Long suiteId) {
        this.suiteId = suiteId;
    }

    public Long getUnitId() {
        return unitId;
    }

    public void setUnitId(Long unitId) {
        this.unitId = unitId;
    }

    public Long getBuildingId() {
        return buildingId;
    }

    public void setBuildingId(Long buildingId) {
        this.buildingId = buildingId;
    }

    public Long getVillageId() {
        return villageId;
    }

    public void setVillageId(Long villageId) {
        this.villageId = villageId;
    }

    public String getOwnerName() {
        return ownerName;
    }

    public void setOwnerName(String ownerName) {
        this.ownerName = ownerName;
    }

    public String getCertNo() {
        return certNo;
    }

    public void setCertNo(String certNo) {
        this.certNo = certNo;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getWeixin() {
        return weixin;
    }

    public void setWeixin(String weixin) {
        this.weixin = weixin;
    }

    public String getQq() {
        return qq;
    }

    public void setQq(String qq) {
        this.qq = qq;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public Integer getIsEmployee() {
        return isEmployee;
    }

    public void setIsEmployee(Integer isEmployee) {
        this.isEmployee = isEmployee;
    }

    public Integer getOwnerStatus() {
        return ownerStatus;
    }

    public void setOwnerStatus(Integer ownerStatus) {
        this.ownerStatus = ownerStatus;
    }
}
